import qs from 'query-string';
import React from 'react'
import { useLocation } from 'react-router-dom'

type Props = {}

export default function P1({}: Props) {
  let location = useLocation()  //提取编程式导航参数，及其他路由信息
  console.log('p1',location);
  let user = qs.parse(location.search) //提取并使用search参数
  return (
    <div>1号产品,{user.name}</div>
  )
}